﻿using ERP.Domain.Entities;
using ERP.Repositories;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ERP.Application.Suppliercustomers
{
    /// <summary>
    /// 供货商服务
    /// </summary>
    public class SuppliercustomerDataService : ISuppliercustomerDataService
    {
        /// <summary>
        /// 供货商仓储
        /// </summary>
        private readonly IRepository<SupplierCustomerInfo> supplierCustomerInfoRepository;

        /// <summary>
        /// 构造方法
        /// </summary>
        /// <param name="supplierCustomerInfoRepository">供货商仓储</param>
        public SuppliercustomerDataService(IRepository<SupplierCustomerInfo> supplierCustomerInfoRepository)
        {
            this.supplierCustomerInfoRepository = supplierCustomerInfoRepository;
        }
        /// <summary>
        /// 获取供应商信息
        /// </summary>
        /// <returns>返回供应商信息</returns>
        public async Task<IList<SupplierCustomerInfo>> GetSupplierCustomerInfos()
        {
            return await supplierCustomerInfoRepository.GetAllAsync();
        }
        


    }
}
